package com.newear.marathon.mapper;

import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
import com.newear.marathon.dto.admin.inquiry.AdminRoleInquiryPageRequestDTO;
import com.newear.marathon.dto.admin.inquiry.AdminRoleInquiryPageResponseSubDTO;
import com.newear.marathon.entity.admin.AdminRole;
import org.apache.ibatis.annotations.Param;

import java.util.List;

/**
 * <p>
 *  Mapper 接口
 * </p>
 *
 * @author MicroBin
 * @since 2021/3/27
 */
public interface AdminRoleMapper extends BaseMapper<AdminRole>
{

    List<AdminRoleInquiryPageResponseSubDTO> queryRolePage(Page<AdminRoleInquiryPageResponseSubDTO> page,
                                                                      @Param("requestDTO") AdminRoleInquiryPageRequestDTO requestDTO);

    List<AdminRole> findByUserId(Integer userId);
}
